package com.example.demo.entity;

import org.springframework.beans.factory.FactoryBean;
import org.springframework.stereotype.Component;

/**
 * @author xkx
 * @version 1.0.0
 * @description
 * @since 2019/3/11 11:33
 */
@Component
public class CountryFactoryBean implements FactoryBean<Country> {

  @Override
  public Country getObject() throws Exception {
    return new Country(1L, "中国", "ASIAN");
  }

  @Override
  public Class<?> getObjectType() {
    return Country.class;
  }
}
